<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
	</head>
	<body>
		<script>
			//小于10的情况
			function LessThan(account){
				if(account<10){
					return "0"+account;
				}else{
					return account;
				}
			}
			//时间戳转化为日期格式
			function formatDate(now) { 
				var year=now.getFullYear(); 
				var month=LessThan(now.getMonth()+1); 
				var date=LessThan(now.getDate()); 
				var hour=LessThan(now.getHours()); 
				var minute=LessThan(now.getMinutes()); 
				var second=now.getSeconds(); 
				return year+"-"+month+"-"+date+""+" "+hour+":"+minute+""; 
			} 
			
			
			
			var timestamp=""//时间戳
			var d=new Date(timestamp1); 
			var dd=formatDate(d);
			
		</script>
	</body>
</html>
